package com.matrix.core.pojo;

import java.util.HashMap;
import java.util.Map;

/**
 * 通用校验结果对象
 * @author Administrator
 */
public class VerifyResult {

    private boolean isError;

    private String msg;

    public VerifyResult(boolean isError, String msg) {
        this.isError = isError;
        this.msg = msg;
    }

    public VerifyResult(boolean isError) {
        this.isError = isError;
    }

    private Map<Object, Object> mapInfo;

    public void putInMap(Object key, Object value) {
        if (mapInfo == null) {
            mapInfo = new HashMap<>();
        }
        mapInfo.put(key, value);
    }

    public boolean isError() {
        return isError;
    }

    public void setError(boolean error) {
        isError = error;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    public Map<Object, Object> getMapInfo() {
        return mapInfo;
    }

    public void setMapInfo(Map<Object, Object> mapInfo) {
        this.mapInfo = mapInfo;
    }
}
